package com.example.zhugenew.presenter;

import com.example.mymvplibrary.callback.BaseModelCallback;
import com.example.mymvplibrary.presenter.BasePresenter;
import com.example.zhugenew.bean.BansBean;
import com.example.zhugenew.concation.MainConations;
import com.example.zhugenew.model.HomeModel;
import com.example.zhugenew.view.HomeView;

import java.util.HashMap;
import java.util.List;

public class HomePresenter<T>  extends BasePresenter<MainConations.MainView, HomeModel> implements BaseModelCallback<T> {
    public void getData(String url, int type, HashMap<String,Object> map){
        getModel().getData(this,getLifecleProvider(),url,type,map);
    }
    @Override
    public void onSucess(T t,int type) {
        getmView().showList(t,type);
    }

    @Override
    public void onError(String message, int code) {
        getmView().showError(message,code);
    }
}
 